

<!DOCTYPE html>
<html lang="zh-CN" data-default-color-scheme=auto>



<head>
  <meta charset="UTF-8">
  <link rel="apple-touch-icon" sizes="76x76" href="/blog/img/moon.png">
  <link rel="icon" href="/blog/img/moon.png">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0, shrink-to-fit=no">
  <meta http-equiv="x-ua-compatible" content="ie=edge">
  
  <meta name="theme-color" content="#2f4154">
  <meta name="author" content="Zhan Zhe">
  <meta name="keywords" content="">
  
    <meta name="description" content="集中式版本分布系统：优点，解决了之前版本控制问题，缺点，如果服务器宕机，可能会丢失数据 分布式版本控制系统：有一个服务器，客户端也有自己存储的版本记录，每次提交前先提交到本地的版本记录，再提交到远程服务器的版本记录，并且客户端和客户端也可以相互连接 本地仓库：电脑本地的仓库 远程仓库：服务器的仓库 配置用户名和邮箱 123git config --global user.name &quot;yo">
<meta property="og:type" content="article">
<meta property="og:title" content="Git笔记">
<meta property="og:url" content="https://zhan_zhe.gitee.io/blog/2022/09/05/git/index.html">
<meta property="og:site_name" content="Zhan&#39;s Blog">
<meta property="og:description" content="集中式版本分布系统：优点，解决了之前版本控制问题，缺点，如果服务器宕机，可能会丢失数据 分布式版本控制系统：有一个服务器，客户端也有自己存储的版本记录，每次提交前先提交到本地的版本记录，再提交到远程服务器的版本记录，并且客户端和客户端也可以相互连接 本地仓库：电脑本地的仓库 远程仓库：服务器的仓库 配置用户名和邮箱 123git config --global user.name &quot;yo">
<meta property="og:locale" content="zh_CN">
<meta property="article:published_time" content="2022-09-05T02:00:00.000Z">
<meta property="article:modified_time" content="2022-09-08T02:49:30.677Z">
<meta property="article:author" content="Zhan Zhe">
<meta property="article:tag" content="Git">
<meta name="twitter:card" content="summary_large_image">
  
  
  
  <title>Git笔记 - Zhan&#39;s Blog</title>

  <link  rel="stylesheet" href="https://lib.baomitu.com/twitter-bootstrap/4.6.1/css/bootstrap.min.css" />



  <link  rel="stylesheet" href="https://lib.baomitu.com/github-markdown-css/4.0.0/github-markdown.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/hint.css/2.7.0/hint.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.css" />



<!-- 主题依赖的图标库，不要自行修改 -->
<!-- Do not modify the link that theme dependent icons -->

<link rel="stylesheet" href="//at.alicdn.com/t/font_1749284_hj8rtnfg7um.css">



<link rel="stylesheet" href="//at.alicdn.com/t/font_1736178_lbnruvf0jn.css">


<link  rel="stylesheet" href="/blog/css/main.css" />


  <link id="highlight-css" rel="stylesheet" href="/blog/css/highlight.css" />
  
    <link id="highlight-css-dark" rel="stylesheet" href="/blog/css/highlight-dark.css" />
  




  <script id="fluid-configs">
    var Fluid = window.Fluid || {};
    Fluid.ctx = Object.assign({}, Fluid.ctx)
    var CONFIG = {"hostname":"zhan_zhe.gitee.io","root":"/blog/","version":"1.9.2","typing":{"enable":true,"typeSpeed":70,"cursorChar":"_","loop":false,"scope":[]},"anchorjs":{"enable":true,"element":"h1,h2,h3,h4,h5,h6","placement":"left","visible":"hover","icon":""},"progressbar":{"enable":true,"height_px":3,"color":"#29d","options":{"showSpinner":false,"trickleSpeed":100}},"code_language":{"enable":true,"default":"TEXT"},"copy_btn":true,"image_caption":{"enable":true},"image_zoom":{"enable":true,"img_url_replace":["",""]},"toc":{"enable":true,"placement":"right","headingSelector":"h1,h2,h3,h4,h5,h6","collapseDepth":0},"lazyload":{"enable":true,"loading_img":"/img/loading.gif","onlypost":false,"offset_factor":2},"web_analytics":{"enable":false,"follow_dnt":true,"baidu":null,"google":null,"gtag":null,"tencent":{"sid":null,"cid":null},"woyaola":null,"cnzz":null,"leancloud":{"app_id":null,"app_key":null,"server_url":null,"path":"window.location.pathname","ignore_local":false}},"search_path":"/blog/local-search.xml"};

    if (CONFIG.web_analytics.follow_dnt) {
      var dntVal = navigator.doNotTrack || window.doNotTrack || navigator.msDoNotTrack;
      Fluid.ctx.dnt = dntVal && (dntVal.startsWith('1') || dntVal.startsWith('yes') || dntVal.startsWith('on'));
    }
  </script>
  <script  src="/blog/js/utils.js" ></script>
  <script  src="/blog/js/color-schema.js" ></script>
  


  
<meta name="generator" content="Hexo 5.4.2"></head>


<body>
  

  <header>
    

<div class="header-inner" style="height: 70vh;">
  <nav id="navbar" class="navbar fixed-top  navbar-expand-lg navbar-dark scrolling-navbar">
  <div class="container">
    <a class="navbar-brand" href="/blog/">
      <strong>Rorschach</strong>
    </a>

    <button id="navbar-toggler-btn" class="navbar-toggler" type="button" data-toggle="collapse"
            data-target="#navbarSupportedContent"
            aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
      <div class="animated-icon"><span></span><span></span><span></span></div>
    </button>

    <!-- Collapsible content -->
    <div class="collapse navbar-collapse" id="navbarSupportedContent">
      <ul class="navbar-nav ml-auto text-center">
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/blog/">
                <i class="iconfont icon-home-fill"></i>
                首页
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/blog/archives/">
                <i class="iconfont icon-archive-fill"></i>
                归档
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/blog/categories/">
                <i class="iconfont icon-category-fill"></i>
                分类
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/blog/tags/">
                <i class="iconfont icon-tags-fill"></i>
                标签
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/blog/about/">
                <i class="iconfont icon-user-fill"></i>
                关于
              </a>
            </li>
          
        
        
          <li class="nav-item" id="search-btn">
            <a class="nav-link" target="_self" href="javascript:;" data-toggle="modal" data-target="#modalSearch" aria-label="Search">
              &nbsp;<i class="iconfont icon-search"></i>&nbsp;
            </a>
          </li>
          
        
        
          <li class="nav-item" id="color-toggle-btn">
            <a class="nav-link" target="_self" href="javascript:;" aria-label="Color Toggle">&nbsp;<i
                class="iconfont icon-dark" id="color-toggle-icon"></i>&nbsp;</a>
          </li>
        
      </ul>
    </div>
  </div>
</nav>

  

<div id="banner" class="banner" parallax=true
     style="background: url('/blog/img/default.png') no-repeat center center; background-size: cover;">
  <div class="full-bg-img">
    <div class="mask flex-center" style="background-color: rgba(0, 0, 0, 0.3)">
      <div class="banner-text text-center fade-in-up">
        <div class="h2">
          
            <span id="subtitle" data-typed-text="Git笔记"></span>
          
        </div>

        
          
  <div class="mt-3">
    
    
      <span class="post-meta">
        <i class="iconfont icon-date-fill" aria-hidden="true"></i>
        <time datetime="2022-09-05 10:00" pubdate>
          2022年9月5日 上午
        </time>
      </span>
    
  </div>

  <div class="mt-1">
    
      <span class="post-meta mr-2">
        <i class="iconfont icon-chart"></i>
        
          3.8k 字
        
      </span>
    

    
      <span class="post-meta mr-2">
        <i class="iconfont icon-clock-fill"></i>
        
        
        
          33 分钟
        
      </span>
    

    
    
  </div>


        
      </div>

      
    </div>
  </div>
</div>

</div>

  </header>

  <main>
    
      

<div class="container-fluid nopadding-x">
  <div class="row nomargin-x">
    <div class="side-col d-none d-lg-block col-lg-2">
      

    </div>

    <div class="col-lg-8 nopadding-x-md">
      <div class="container nopadding-x-md" id="board-ctn">
        <div id="board">
          <article class="post-content mx-auto">
            <!-- SEO header -->
            <h1 style="display: none">Git笔记</h1>
            
            
              <div class="markdown-body">
                
                <p>集中式版本分布系统：优点，解决了之前版本控制问题，缺点，如果服务器宕机，可能会丢失数据</p>
<p>分布式版本控制系统：有一个服务器，客户端也有自己存储的版本记录，每次提交前先提交到本地的版本记录，再提交到远程服务器的版本记录，并且客户端和客户端也可以相互连接</p>
<p>本地仓库：电脑本地的仓库</p>
<p>远程仓库：服务器的仓库</p>
<p>配置用户名和邮箱</p>
<figure class="highlight verilog"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><code class="hljs verilog">git <span class="hljs-keyword">config</span> --<span class="hljs-keyword">global</span> user<span class="hljs-variable">.name</span> <span class="hljs-string">&quot;your_username&quot;</span><br>git <span class="hljs-keyword">config</span> --<span class="hljs-keyword">global</span> user<span class="hljs-variable">.email</span> <span class="hljs-string">&quot;your_email@domain.com&quot;</span>  <span class="hljs-comment">//global 表示全局</span><br>git <span class="hljs-keyword">config</span> --list<br></code></pre></td></tr></table></figure>

<p>git 文件三种状态：</p>
<p>已提交：committed  已提交表示数据已经安全的保存在本地数据中</p>
<p>已修改：modified  已修改表示修改了文件，但是还没有保存到本地数据库汇总</p>
<p>已暂存：staged  已暂存表示对一个已修改文件的当前版本做了标记，是指包含在下次提交的快照中</p>
<p>工作目录-&gt;暂存区-&gt;本地仓库</p>
<p>git status 观看暂存区和工作目录里的文件</p>
<p>git add path 通常是通过git add <path></path>的形式把<path></path>添加到索引库中，&lt;path可以是文件也可以是目录，git add 把问天添加到暂存区</p>
<p>git add. 把当前目录下所有目录都提交到暂存区</p>
<p>git rm –cached <file>删除暂存区文件</file></p>
<p>git restore –staged <file> 把暂存区的文件拿出来  ，还原到工作区   || git reset HEAD <file>//取消上一次操作</file></file></p>
<p>git commit  -m “这里写入提交需要注释的信息” 命令用于更改记录（提交）到存储库。将索引的当前内容与描述更改的用户和日志消息一起存储在新的提交中，通常在执行提交时，在git commit 命令后跟上-m属性，加入本次提交的记录说明，方便后续查看提交活改动记录</p>
<figure class="highlight vim"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br></pre></td><td class="code"><pre><code class="hljs vim">//什么都没有操作的文件status<br>nothing added <span class="hljs-keyword">to</span> commit but untracked <span class="hljs-keyword">files</span> present (use <span class="hljs-string">&quot;git add&quot;</span> <span class="hljs-keyword">to</span> track)<br>//进行了git added 后的文件status<br><span class="hljs-keyword">changes</span> <span class="hljs-keyword">to</span> <span class="hljs-keyword">be</span> committed :<br>(use <span class="hljs-string">&quot;git rm --cached &lt;file&gt;...&quot;</span> <span class="hljs-keyword">to</span> unstage)<br>green <span class="hljs-keyword">new</span> <span class="hljs-keyword">file</span>:<span class="hljs-symbol">&lt;filename&gt;</span><br>//进行了 git commit -<span class="hljs-keyword">m</span> <span class="hljs-string">&#x27;第一次提交&#x27;</span>后的反馈信息<br>[master (root-commit) *****] 第一次提交<br><span class="hljs-number">1</span> <span class="hljs-keyword">file</span> changed,<span class="hljs-number">1</span> insertion(+)<br>create <span class="hljs-keyword">mode</span> <span class="hljs-number">100644</span> git01.txt<br>//进行了 git commit -<span class="hljs-keyword">m</span> <span class="hljs-string">&#x27;第一次提交&#x27;</span>后的status信息<br><span class="hljs-keyword">on</span> branch master <br>nothing <span class="hljs-keyword">to</span> commit, working tree clean<br>//进行 git commit -<span class="hljs-keyword">m</span> <span class="hljs-string">&#x27;第一次提交&#x27;</span>后的git <span class="hljs-built_in">log</span> 信息<br>commit f298uds8af78saf89asdf89as8faf9s8f8asf9d8s(HEAD-&gt;master)<br>Author: name &lt;<span class="hljs-number">425255397</span>@qq.<span class="hljs-keyword">com</span>&gt;<br>Date :**********<br>第一次提<br>//当提交的文件进行修改了以后<br>git status<br><span class="hljs-keyword">on</span> branch master <br>Changes not statged <span class="hljs-keyword">for</span> commi<span class="hljs-variable">t:</span><br>(use <span class="hljs-string">&quot;git add&lt;file&gt; ...&quot;</span> <span class="hljs-keyword">to</span> <span class="hljs-keyword">update</span> what will <span class="hljs-keyword">be</span> committed)<br>(use <span class="hljs-string">&quot;git restore &lt;file&gt;.. &quot;</span>)<span class="hljs-keyword">to</span> discard <span class="hljs-keyword">changes</span> in working directory)<br>		modified : <span class="hljs-symbol">&lt;filename&gt;</span><br><span class="hljs-keyword">no</span> <span class="hljs-keyword">changes</span> <span class="hljs-built_in">add</span> <span class="hljs-keyword">to</span> commit(use <span class="hljs-string">&quot;git add&quot;</span> <span class="hljs-built_in">and</span>/<span class="hljs-built_in">or</span> <span class="hljs-string">&quot;git commit -a&quot;</span>)<br><br></code></pre></td></tr></table></figure>



<p>git diff HEAD – <file>    //查看git 本地库与工作区文件的区别，head是指针</file></p>
<p>— a/git01.txt变动之前的文件</p>
<p>+++ b/git01.txt</p>
<p>@@-1,2 +1,3@@变动之前从第一行开始连续两行，变动之后从第一行开始连续三行</p>
<p>git log //命令用于显示提交日志信息</p>
<p>git commit -am ‘第四次提交’ <file> //-a就是add的缩写，相当于 git add. + git commit -m ‘第四次提交’</file></p>
<p>git log –pretty=oneline //当log信息太多时，仅仅展示提交id信息和提交备注信息，不显示其他信息</p>
<p>git reset –hard HEAD^ //往后回退一个版本</p>
<p>git reset –hard HEAD~2 //往后回退两个版本</p>
<p>git reset –hard b1901234kdsaf   //转到这一次唯一id对应的提交的版本，这个id不用全部打完，仅仅能够起到与其他id不重复不冲突的最基本功能的前几位即可</p>
<p>git reflog //当git log 展示不出唯一标识时候，可以使用git reflog来查看唯一标识</p>
<p>git ls-files  //看git本地仓库里面的文件目录</p>
<p>git checkout <file> //从本地仓库拉下特定文件</file></p>
<figure class="highlight vim"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br></pre></td><td class="code"><pre><code class="hljs vim">//当手动删除工作目录下文件后<br>//键入命令git status ,会出现以下提示<br>On branch maseter<br>Changes not staged <span class="hljs-keyword">for</span> commi<span class="hljs-variable">t:</span><br>	(use <span class="hljs-string">&quot;git add/rm &lt;file&gt;...&quot;</span> <span class="hljs-keyword">to</span> <span class="hljs-keyword">update</span> what will <span class="hljs-keyword">be</span> committed)<br>	(use <span class="hljs-string">&quot;git restore &lt;file&gt;...&quot;</span> <span class="hljs-keyword">to</span> discard <span class="hljs-keyword">changes</span> in working directory)<br>		(红色)deleted: git02.txt<br><span class="hljs-keyword">no</span> <span class="hljs-keyword">changes</span> added <span class="hljs-keyword">to</span> commit (use <span class="hljs-string">&quot;git add &quot;</span> <span class="hljs-built_in">and</span>/<span class="hljs-built_in">or</span> <span class="hljs-string">&quot;git commit -a&quot;</span>)<br>//可以通过git <span class="hljs-built_in">add</span> git02.txt,将删除文件的相关信息键入缓存区,键入该命令后在键入git status会出现以下提示<br>On branch master<br>Changes <span class="hljs-keyword">to</span> <span class="hljs-keyword">be</span> committed:<br>	(use <span class="hljs-string">&quot;git restore --staged &lt;file&gt;...&quot;</span> <span class="hljs-keyword">to</span> unstage)<br>		deleted: git02.txt<br>//当再次键入git commit -<span class="hljs-keyword">m</span> <span class="hljs-string">&#x27;删除git02.txt&#x27;</span>命令后出现以下提示，即可删除本地仓库的文件<br>[master <span class="hljs-number">562</span>ca3f] 删除git02.txt<br><span class="hljs-number">1</span> <span class="hljs-keyword">file</span> changed,<span class="hljs-number">1</span> deletion(-)<br><span class="hljs-keyword">delete</span> <span class="hljs-keyword">mode</span> <span class="hljs-number">100644</span> git02.txt<br>//此时通过git <span class="hljs-keyword">ls</span>-<span class="hljs-keyword">files</span> 查看本地仓库是看不到删除的文件的，代表文件完全删除<br>//对于git命令而言，所做的每一次修改都是<br></code></pre></td></tr></table></figure>

<figure class="highlight stata"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><code class="hljs stata"><span class="hljs-comment">//删除方法二</span><br>git <span class="hljs-keyword">rm</span> &lt;<span class="hljs-keyword">file</span>&gt;<br><br></code></pre></td></tr></table></figure>

<figure class="highlight awk"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br></pre></td><td class="code"><pre><code class="hljs awk"><span class="hljs-regexp">//</span>通过git clone下载github代码<br>git clone https:<span class="hljs-regexp">//gi</span>thub.com/*********<br><span class="hljs-regexp">//</span>将ssh传输到github进行认证<br>ssh -T git@github.com<br><span class="hljs-regexp">//</span>通过ssh的方式进行下载还是git clone<br>git clone git@github.com:winterbe/java8-tutorial.git<br><span class="hljs-regexp">//</span>注意，通过两种传输协议传输只有网址不同，其他的都相同<br><span class="hljs-regexp">//</span>切换到主干分支<br>git branch -M master<br><span class="hljs-regexp">//</span>给远程的git仓库起一个名字交 originzz，并将其绑定到本地git上，只做一次就可以了<br>git remote add originzz git@github.com:MrcodeZZ/git01.git<br><span class="hljs-regexp">//</span>将本地代码的主分支推到github上<br>git push -u originzz master<br><span class="hljs-regexp">//</span>后面再推就git push就可以了<br></code></pre></td></tr></table></figure>

<h1 id="git分支操作"><a href="#git分支操作" class="headerlink" title="git分支操作"></a>git分支操作</h1><p>开发企业项目中在使用Git或者其他类似版本控制软件队项目版本进行管理时，多人合作的项目在开发时通常不会直接在主干master上进行操作，而是重新开辟新的分支，在新的分支上进行开发调试等操作，当项目调试通过时才会将分支项目的代码合并到主干中，这是在实战中比较好的一种策略，特别是多人协同开发一个项目的情况下尤其明显，git对于分支操作提供了以下基本命令</p>
<figure class="highlight awk"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><code class="hljs awk">git checkout &lt;branch&gt; <span class="hljs-regexp">//</span>切换到指定分支<br>git checkout -b &lt;new_branch&gt; <span class="hljs-regexp">//</span>新建分支并切换到新建分支<br>git branch -d branck <span class="hljs-regexp">//</span>删除指定分支<br>git branch <span class="hljs-regexp">//</span>查看所有分支，并且*号标记当前所在分支<br>git merge branch <span class="hljs-regexp">//</span>合并分支<br>git branch -m|-M old branch newbranch <span class="hljs-regexp">//</span>重命名分支，如果new branch 名字已经存在，则需要用-M强制重命名，否则，使用-m进行重命名<br></code></pre></td></tr></table></figure>

<p>如果是一个新的项目，直接一个主干开发就行</p>
<p>如果已经上线了，就不能在主干上开发，如果在主干上开发，则主干可能有bug，可能导致宕机</p>
<p>第一个git/Linux</p>

                
              </div>
            
            <hr/>
            <div>
              <div class="post-metas my-3">
  
    <div class="post-meta mr-3 d-flex align-items-center">
      <i class="iconfont icon-category"></i>
      

<span class="category-chains">
  
  
    
      <span class="category-chain">
        
  <a href="/blog/categories/%E5%BC%80%E5%8F%91%E5%B7%A5%E5%85%B7/" class="category-chain-item">开发工具</a>
  
  
    <span>></span>
    
  <a href="/blog/categories/%E5%BC%80%E5%8F%91%E5%B7%A5%E5%85%B7/Git/" class="category-chain-item">Git</a>
  
  

  

      </span>
    
  
</span>

    </div>
  
  
    <div class="post-meta">
      <i class="iconfont icon-tags"></i>
      
        <a href="/blog/tags/Git/">#Git</a>
      
    </div>
  
</div>


              
  

  <div class="license-box my-3">
    <div class="license-title">
      <div>Git笔记</div>
      <div>https://zhan_zhe.gitee.io/blog/2022/09/05/git/</div>
    </div>
    <div class="license-meta">
      
        <div class="license-meta-item">
          <div>作者</div>
          <div>Zhan Zhe</div>
        </div>
      
      
        <div class="license-meta-item license-meta-date">
          <div>发布于</div>
          <div>2022年9月5日</div>
        </div>
      
      
      <div class="license-meta-item">
        <div>许可协议</div>
        <div>
          
            
            
              <a target="_blank" href="https://creativecommons.org/licenses/by/4.0/">
              <span class="hint--top hint--rounded" aria-label="BY - 署名">
                <i class="iconfont icon-by"></i>
              </span>
              </a>
            
          
        </div>
      </div>
    </div>
    <div class="license-icon iconfont"></div>
  </div>



              
                <div class="post-prevnext my-3">
                  <article class="post-prev col-6">
                    
                    
                      <a href="/blog/2022/09/08/ImageNet-Classification-wiht-Deep-Convolutional-Neural-Networks/" title="ImageNet Classification wiht Deep Convolutional Neural Networks">
                        <i class="iconfont icon-arrowleft"></i>
                        <span class="hidden-mobile">ImageNet Classification wiht Deep Convolutional Neural Networks</span>
                        <span class="visible-mobile">上一篇</span>
                      </a>
                    
                  </article>
                  <article class="post-next col-6">
                    
                    
                      <a href="/blog/2022/09/05/hello/" title="hello这个文件">
                        <span class="hidden-mobile">hello这个文件</span>
                        <span class="visible-mobile">下一篇</span>
                        <i class="iconfont icon-arrowright"></i>
                      </a>
                    
                  </article>
                </div>
              
            </div>

            
          </article>
        </div>
      </div>
    </div>

    <div class="side-col d-none d-lg-block col-lg-2">
      
  <aside class="sidebar" style="margin-left: -1rem">
    <div id="toc">
  <p class="toc-header"><i class="iconfont icon-list"></i>&nbsp;目录</p>
  <div class="toc-body" id="toc-body"></div>
</div>



  </aside>


    </div>
  </div>
</div>





  



  



  



  



  







    

    
      <a id="scroll-top-button" aria-label="TOP" href="#" role="button">
        <i class="iconfont icon-arrowup" aria-hidden="true"></i>
      </a>
    

    
      <div class="modal fade" id="modalSearch" tabindex="-1" role="dialog" aria-labelledby="ModalLabel"
     aria-hidden="true">
  <div class="modal-dialog modal-dialog-scrollable modal-lg" role="document">
    <div class="modal-content">
      <div class="modal-header text-center">
        <h4 class="modal-title w-100 font-weight-bold">搜索</h4>
        <button type="button" id="local-search-close" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">&times;</span>
        </button>
      </div>
      <div class="modal-body mx-3">
        <div class="md-form mb-5">
          <input type="text" id="local-search-input" class="form-control validate">
          <label data-error="x" data-success="v" for="local-search-input">关键词</label>
        </div>
        <div class="list-group" id="local-search-result"></div>
      </div>
    </div>
  </div>
</div>

    

    
  </main>

  <footer>
    <div class="footer-inner">
  
    <div class="footer-content">
       <a href="https://github.com/MrcodeZZ" target="_blank" rel="nofollow noopener"><span>Zhe</span></a> <i class="iconfont icon-love"></i> <a href="https://github.com/fluid-dev/hexo-theme-fluid" target="_blank" rel="nofollow noopener"><span>Yan</span></a> 
    </div>
  
  
  
  
</div>

  </footer>

  <!-- Scripts -->
  
  <script  src="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.js" ></script>
  <link  rel="stylesheet" href="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.css" />

  <script>
    NProgress.configure({"showSpinner":false,"trickleSpeed":100})
    NProgress.start()
    window.addEventListener('load', function() {
      NProgress.done();
    })
  </script>


<script  src="https://lib.baomitu.com/jquery/3.6.0/jquery.min.js" ></script>
<script  src="https://lib.baomitu.com/twitter-bootstrap/4.6.1/js/bootstrap.min.js" ></script>
<script  src="/blog/js/events.js" ></script>
<script  src="/blog/js/plugins.js" ></script>


  <script  src="https://lib.baomitu.com/typed.js/2.0.12/typed.min.js" ></script>
  <script>
    (function (window, document) {
      var typing = Fluid.plugins.typing;
      var subtitle = document.getElementById('subtitle');
      if (!subtitle || !typing) {
        return;
      }
      var text = subtitle.getAttribute('data-typed-text');
      
        typing(text);
      
    })(window, document);
  </script>




  
    <script  src="/blog/js/img-lazyload.js" ></script>
  




  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/tocbot/4.18.2/tocbot.min.js', function() {
    var toc = jQuery('#toc');
    if (toc.length === 0 || !window.tocbot) { return; }
    var boardCtn = jQuery('#board-ctn');
    var boardTop = boardCtn.offset().top;

    window.tocbot.init({
      tocSelector     : '#toc-body',
      contentSelector : '.markdown-body',
      headingSelector : CONFIG.toc.headingSelector || 'h1,h2,h3,h4,h5,h6',
      linkClass       : 'tocbot-link',
      activeLinkClass : 'tocbot-active-link',
      listClass       : 'tocbot-list',
      isCollapsedClass: 'tocbot-is-collapsed',
      collapsibleClass: 'tocbot-is-collapsible',
      collapseDepth   : CONFIG.toc.collapseDepth || 0,
      scrollSmooth    : true,
      headingsOffset  : -boardTop
    });
    if (toc.find('.toc-list-item').length > 0) {
      toc.css('visibility', 'visible');
    }
  });
</script>


  <script src=https://lib.baomitu.com/clipboard.js/2.0.10/clipboard.min.js></script>

  <script>Fluid.plugins.codeWidget();</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/anchor-js/4.3.1/anchor.min.js', function() {
    window.anchors.options = {
      placement: CONFIG.anchorjs.placement,
      visible  : CONFIG.anchorjs.visible
    };
    if (CONFIG.anchorjs.icon) {
      window.anchors.options.icon = CONFIG.anchorjs.icon;
    }
    var el = (CONFIG.anchorjs.element || 'h1,h2,h3,h4,h5,h6').split(',');
    var res = [];
    for (var item of el) {
      res.push('.markdown-body > ' + item.trim());
    }
    if (CONFIG.anchorjs.placement === 'left') {
      window.anchors.options.class = 'anchorjs-link-left';
    }
    window.anchors.add(res.join(', '));
  });
</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.js', function() {
    Fluid.plugins.fancyBox();
  });
</script>


  <script>Fluid.plugins.imageCaption();</script>

  <script  src="/blog/js/local-search.js" ></script>





<!-- 主题的启动项，将它保持在最底部 -->
<!-- the boot of the theme, keep it at the bottom -->
<script  src="/blog/js/boot.js" ></script>


  

  <noscript>
    <div class="noscript-warning">博客在允许 JavaScript 运行的环境下浏览效果更佳</div>
  </noscript>
</body>
</html>
